<!DOCTYPE html>
<html>
<head>
<title>购物车</title>
<?php $this->load->view('common/include');?>
<style>
.bo-checked:after {
  position: absolute;
  right: -8px;
  top: -3.2px;
  font-family: iconfont;
  content: '';
  font-size: 16px;
  color: #999;
}
.bo-box-title{
	color:#FF6633;
	font-size: 14px;
}
</style>
</head>
<body id="app" v-cloak>
	<header-layout title='Bone Vue'>
		<header-dock align='left'>
			<a href="<?php echo site_url('/home'); ?>"><Icon type="back"></Icon></a>
		</header-dock>
		购物车
		<header-dock align='right'>
			<Btn @btn-click="clean" name="清 空"></Btn>
		</header-dock>
	</header-layout> 
	<layout-main>
		<div v-for="items in data" v-if="items.show">
			<div class="bo-box-title">
				<Icon type="time"></Icon>
			{{items.date}}</div>
			<layout-box p="1111" v-if="items.empty">
				<a  style="float:right" href="<?php echo site_url();?>/home?today={{$index+1}}"><i class="icon iconfont icon-forward"></i> 去选购</a>  
				这天没有添加商品 		 
			</layout-box>
			<layout-box p="1111" v-for="item in items.data" >
				<product2 :data="item" @product-buy="delete" max="1"></product2>				 
			</layout-box>
		</div>
	</layout-main>
	<?php
 $code = mt_rand(0,1000000);
 ?>
	<input type="hidden" id="code" value="<?php echo $code;?>">
	<shopping-dock :total="total" @shoppingdock-go="pay" name="提交订单"></shopping-dock>
	<script>
		var PRODUCTS = <?php echo json_encode($shoppingcart);?>;
		var DATE = <?=json_encode($date)?>;
	</script>
	<script src="js/shoppingcart.build.js?v=1.2.2"></script>
</body>
</html>
